1. Field of the Invention
The present invention generally relates to a moving picture compression and decompression system, and more particularly to an apparatus and method for concealing an error in a moving picture decompression system.
2. Description of the Related Art
Utilizing a digital signal processing technology, many systems have been proposed to compress and transmit a large amount of moving picture information through a transmission channel of a limited bandwidth. In moving picture standards such as MPEG, H.261 and H.263, re-synchronization due to channel errors is performed in units of a slice. Each slice consists of a plurality of macro blocks and each macro block is the unit for motion compensation decoding. A single frame generally includes many slices depending upon the size of an image. When an error is generated in such a slice, all information in the slice with the error is lost.
Also, moving picture coding methods use both a variable length coding and a motion compensation coding. In such case, an error in a bit of a bit stream results in a loss of a considerable portion of the picture information and continuously affects the following frames. Accordingly, a severe deterioration in a picture quality results when a decoder decodes a bit stream with an error. To solve this problem, numerous methods for error concealment using neighboring information to restore the lost information has been proposed. Typical concealment methods include spatial prediction error concealment, temporal prediction error concealment, and error concealment using additional information.
The spatial prediction error concealing method compensates a lost picture block by an interpolation of the neighboring blocks in the spatial domain. An error concealment based on a projection is representative of a spatial prediction error concealment. The spatial prediction error concealment performs well if the lost block is small compared to the overall size of an image, but involves a great amount of calculation at the receiving terminal. Also, a loss may be linearly compensated up to a certain degree by a complicated algorithm, but a smoothing of a curved line or texture may result due to such compensation.
The temporal prediction error concealing method compensates a lost picture block using a motion vector in the time domain. Although this method is relatively simple and can quickly compensates a lost block, the accuracy of the compensated block is not high. The temporal prediction concealing method especially results in a low performance when there is a fast motion or irregular motion between two continuous frames.
Finally, error concealment methods using additional information inserts an additional information within the user data portion in anticipation of and to compensate an error if an error occurs. However, these methods also has drawbacks in that the amount of data increases due to the insertion of the additional information.
A temporal prediction error concealment method for a moving picture compression and decompression system in the related art will next be described with reference to FIG. 1.
In FIG. 1, a picture is divided into 16*16 macroblocks in conformation of most moving picture standards, where several macroblocks are consecutively damaged. A picture is processed in a unit of the macroblock and several macroblocks form a slice. Also, one frame includes several slices according to the size of the picture. According to the temporal prediction error concealment method, the damaged macroblocks E(n) within a current frame are substituted by macroblocks positioned at the same locations in a previous frame or are substituted by macroblocks of a previous frame using motion information of upper macroblocks MB(n) over the damaged macroblocks.
However, such error concealment methods have a drawback in that the substituted upper macroblock may have a low relationship with the damaged macroblock when a damaged macroblock is a macroblock having motion. On the other hand, when the upper macroblock has no motion, a wrong macroblock may be substituted for the damaged macroblock, resulting in a low efficiency.
Accordingly, an object of the present invention is to solve at least the problems and disadvantages of the related art.
An object of the present invention is to provide an efficient apparatus and method for concealing error in a moving picture decompression system.
Another object of the present invention is to provide an apparatus and method for concealing error in a moving picture decompression system which compensates a damaged macroblock by predicting motion vectors of the damaged macroblock utilizing motion information of both neighboring macroblocks such as a previous macroblock and an upper macroblock.
A further object of the present invention is to provide an apparatus and method for concealing error in a moving picture decompression system which compensates a damaged macroblock by predicting motion vectors of a damaged macroblock utilizing motion information of neighboring macroblocks, stores the predictive motion vectors, and adaptively uses the stored motion information for error concealment of subsequently damaged macroblocks.
Additional advantages, objects, and features of the invention will be set forth in part in the description which follows and in part will become apparent to those having ordinary skill in the art upon examination of the following or may be learned from practice of the invention. The objects and advantages of the invention may be realized and attained as particularly pointed out in the appended claims.
To achieve the objects and in accordance with the purposes of the invention, as embodied and broadly described herein, an apparatus for concealing error in moving picture decompression system includes a motion vector decoder; a macroblock reconstruction controller; a motion concealment unit for storing a predictive motion vector from the motion vector decoder depending on a control signal and an error_flag which are output from the macroblock reconstruction controller, and for compensating a damaged macroblock using a stored motion information of a previous macroblock; and a motion vector memory for storing the motion information depending on a signal from the motion concealment unit and for outputting the motion information of the previous macroblock to the motion concealment unit depending on the control signal.
In the above error concealment apparatus, the motion information is a motion information of an upper macroblock positioned immediately over the damaged macroblock and a motion information of a left macroblock positioned adjacent to the left side of the damaged macroblock. Also, the motion information is a macroblock type, a motion coding type, a motion vertical field select signal, and two motion vectors with respect to both a motion information of the upper macroblock and a motion information of the left macroblock.
The motion concealment unit of the error concealment apparatus according to the present invention includes a motion concealment controller for controlling the entire operation of the motion concealment unit depending on the control signal and error_flag output from the macroblock reconstruction controller; a prediction motion vector latch unit for latching macroblock parameters and motion vectors depending on a control signal of the motion concealment controller; a prediction motion vector decision unit for determining a predictive motion vector depending on the macroblock parameters latched by the prediction motion vector latch unit; a multiplexer for multiplexing predictive motion vectors or error concealment motion vectors into respective macroblock parameters and predictive motion vector data depending on whether the error_flag from the macroblock reconstruction controller exists; a macroblock parameter register unit for temporarily storing the macroblock parameters from the multiplexer according to picture coding parameters from the macroblock reconstruction controller; an address generating unit for generating macroblock addresses depending on signals of macroblock modes and motion types output from the macroblock parameter register unit and signal of pmv data output from the multiplexer according to the control signal of the motion concealment controller; an error concealment motion vector generating unit for converting current macroblock output from the multiplexer to bit streams depending on a control signal mvb_w_flag from the motion concealment controller unit, and storing the converted bit streams in the motion vector memory (MV_memory); a delay unit for delaying a motion information (ecmv data (n)) of the current macroblock from the error concealment motion vector generating unit for a predetermined time and outputting the motion information after the delay time; an error concealment motion vector latch unit for latching the previous macroblock stored in the motion vector memory depending on control signal output from the motion concealment controller; and an error concealment motion decision unit for determining error concealment motion vector depending on both signal output from the error concealment motion vector latch unit and a motion information of the previous macroblock delayed by the delay unit.
A method for concealing an error in a moving picture compression and decompression system according to the present invention includes: storing a motion information of a macroblock corresponding to a received signal; delaying the motion information by temporarily storing the motion information for a predetermined time; and performing an error concealment using the stored motion information and the delayed motion information when an error flag is input due to a generation of a damaged macroblock.
In the error concealment method, the storing step stores a picture coding type and a motion type of a macroblock that is currently decoded, and a motion information of an upper macroblock positioned immediately over the damaged macroblock and a motion information of a left macroblock positioned adjacent to the left side of the damaged macroblock, the motion information of the upper macroblock and the left macroblock being macroblock type, motion type, motion vertical field select, and motion vector. Also, the error concealment step conceals the error by substituting a macroblock adjacent to the damaged macroblock for the damaged macroblock using the motion information of the upper macroblock and the left macroblock. The error concealment step conceals the error depending on the picture coding type of the damaged macroblock.
More particularly, the error concealment step is performed using a macroblock at the same position within a previous frame when the picture coding type is an intra mode; by using the motion information of the upper macroblock over the damaged macroblock when the picture coding type is P-picture, B-picture or I-picture in which an error concealment motion vector is contained and when the upper macroblock type is different from the left macroblock type; by using the motion type when the upper macroblock type is the same with the left macroblock type. Namely, the error concealment step is executed using an average value of the two motion vectors of the two macroblocks when the upper macroblock type is the same with the left macroblock type, and using the motion vector of the upper macroblock when the upper macroblock type is different from the left macroblock type.
The error concealment apparatus and method in moving picture compression and decompression system according to the present invention stores motion information of a macroblock of a received signal, delays the motion information for a predetermined time, temporarily stores the motion information, and performs error concealment using the stored motion information and the delayed motion information when inputting error_flag depending on occurrence of the damaged macroblock. Thus, the motion vector of the damaged macroblock can be predicted more accurately without the necessity of additional hardwares, thereby enhancing visible effect of reconstructed picture under various error environments and providing excellent picture quality on measuring objective peak to peak signal noise to ratio.